package main

import (
	"fmt"
	"runtime"
)

func main() {
	pc := make([]uintptr, 10)
	n := runtime.Callers(0, pc)
	fmt.Println(n)
	frames := runtime.CallersFrames(pc[:n])
	for {
		frame, more := frames.Next()
		fmt.Printf("%s:%d %s\n", frame.File, frame.Line, frame.Function)
		if !more {
			break
		}
	}
}
